﻿using System;
using System.Collections.Generic;

namespace MSAP.ObjectsStore
{
    public interface IRecordSet<TRECORD> where TRECORD : RecordBase<TRECORD>, new()
    {
        TRECORD CreateRecord();
        TRECORD LoadRecord(Guid _Oid);

        void AddRecord(TRECORD theRecord);
        void DeleteRecord(Guid Oid);
        TRECORD GetRecord(Guid Oid);

        void Save(string sFileName);
        void Save(string sFileName, List<Guid> lstGuid);
        void Load(string sFileName);

        event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;

        System.Collections.ObjectModel.ObservableCollection<TRECORD> Records { get; }
    }
}
